package com.sy.service.Impl;

import com.sy.entity.Area;
import com.sy.entity.Cartoon;
import com.sy.entity.Theme;
import com.sy.mapper.CartoonMapper;
import com.sy.service.CartoonService;
import com.sy.vo.CartoonVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Set;

@Service
public class CartoonServiceImpl implements CartoonService {

    @Autowired
    private CartoonMapper mapper;

    @Override
    public Cartoon getCartoonById(Integer id) {
        return mapper.selectById(id);
    }

    @Override
    public List<Cartoon> selectCartoonTen(Set<Integer> ids) {
        return mapper.selectCartoonTen(ids);
    }

    @Override
    public List<Cartoon> getAdventureCartoon() {
        return mapper.getAdventureCartoon();
    }

    @Override
    public List<Cartoon> getPassionateCartoon() {
        return mapper.getPassionateCartoon();
    }

    @Override
    public List<Theme> getAllTheme() {
        return mapper.getAllTheme();
    }

    @Override
    public List<Area> getAllArea() {
        return mapper.getAllArea();
    }

    @Override
    public List<Cartoon> classifySelect(CartoonVo vo) {
        return mapper.classifySelect(vo);
    }

    @Override
    public List<Cartoon> getSortByJapan() {
        return mapper.getSortByJapan();
    }

    @Override
    public List<Cartoon> getSortByChina() {
        return mapper.getSortByChina();
    }

    @Override
    public List<Cartoon> getSortByMonthly() {
        return mapper.getSortByMonthly();
    }

    @Override
    public List<Cartoon> getSortByGratis() {
        return mapper.getSortByGratis();
    }

    @Override
    public List<Cartoon> getSearch(String cName) {
        return mapper.getSearch(cName);
    }

    @Override
    public int updateClickNumber(Integer id) {
        return mapper.updateClickNumber(id);
    }

    @Override
    public List<Cartoon> getSortByClick() {
        return mapper.getSortByClick();
    }
}
